/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package CompanyPackage;

import FrameWork.RoomCreatorEngine;
import FrameWork.RoomOperator;
import FrameWork.UserCreatorEngine;
import NetworkReceiver.NetworkObserver;

/**
 *
 * @author Ahmed Osama
 */
public class NewMain {

    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) {
        // TODO code application logic here
        
        RoomOperator serverController = RoomOperator.instance();
        RoomCreatorEngine roomEngine = new RoomCreatorEngine();
        serverController.roomBuilderAction("MainServer", 1, roomEngine);
        NetworkObserver networkObserver = NetworkObserver.getInstance();
        networkObserver.start();
       
        while(true)
        {
            serverController.operate();
            if(serverController.exitFlag)
                break;
        }
        
    }

}
